package April._17.work2;

import java.io.File;
import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.IOException;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) throws IOException {
        Scanner scanner = new Scanner(System.in);
        String str =null;
        FileOutputStream fileOut = new FileOutputStream("fileTest\\a.txt");
        while(!(str=scanner.nextLine()).equals("end")){
            fileOut.write(str.getBytes());
            fileOut.write("\r\n".getBytes());

        }
        fileOut.close();
    }
}
